<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            width: 100px;
            height: 100px;
            background: skyblue;
            position: absolute;
        }
    </style>
    <script src="js/scroll.js"></script>
</head>
<body>
    <button>斜着走</button>
    <div class="box"></div>
    <script>
        let oBtns=document.querySelectorAll("button");
        let oBox=document.querySelector(".box");
        oBtns[0].onclick=()=>{
            var json={
                left:"100px",
                top:"500px",
                zIndex:1,
                opacity:0.5
            }
            utils.animate(oBox,json,function(){
                alert("已经完成");
            })
        }
    </script>
</body>
</html>